﻿using Domain.Base;
using SqlSugar;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Text;
using System.Text.Json.Serialization;

namespace Domain.Entity
{
   public class BaseEntity: BaseOperateObject
    {
        /// <summary>
        /// 编号
        /// </summary>
        [SugarColumn(ColumnName = "Id", IsPrimaryKey = true, IsIdentity = false)]
        [Description("编号")]
        public long Id { get; set; } = 0;
        /// <summary>
        /// 是否删除
        /// </summary>
        [Description("是否删除")]
        [SugarColumn(ColumnName = "IsDeleted")]
        [JsonIgnore]
        public bool IsDeleted { get; set; } = false;
        /// <summary>
        /// 创建人
        /// </summary>
        [Description("创建人")]
        [SugarColumn(ColumnName = "Creator")]
        public string Creator { get; set; }
        /// <summary>
        /// 创建人ID
        /// </summary>
        [SugarColumn(ColumnName = "CreatorId")]
        public long? CreatorId { get; set; } = 0;
        /// <summary>
        /// 创建时间
        /// </summary>
        [Description("创建时间")]
        [SugarColumn(ColumnName = "CreateTime")]
        public DateTime CreateTime { get; set; } = DateTime.Now;
    }
}
